
package std.unicode
import std.collection.*


@!APILevel[
    since: "22"
]
public enum CasingOption {
    @!APILevel[
        since: "22"
    ]
    TR |
    @!APILevel[
        since: "22"
    ]
    AZ |
    @!APILevel[
        since: "22"
    ]
    LT |
    @!APILevel[
        since: "22"
    ]
    Other
}

@!APILevel[
    since: "22"
]
public interface UnicodeRuneExtension {
    @!APILevel[
        since: "22"
    ]
    func isLetter(): Bool
    
    @!APILevel[
        since: "22"
    ]
    func isNumber(): Bool
    
    @!APILevel[
        since: "22"
    ]
    func isLowerCase(): Bool
    
    @!APILevel[
        since: "22"
    ]
    func isUpperCase(): Bool
    
    @!APILevel[
        since: "22"
    ]
    func isTitleCase(): Bool
    
    @!APILevel[
        since: "22"
    ]
    func isWhiteSpace(): Bool
    
    @!APILevel[
        since: "22"
    ]
    func toUpperCase(): Rune
    
    @!APILevel[
        since: "22"
    ]
    func toLowerCase(): Rune
    
    @!APILevel[
        since: "22"
    ]
    func toTitleCase(): Rune
    
    @!APILevel[
        since: "22"
    ]
    func toUpperCase(opt: CasingOption): Rune
    
    @!APILevel[
        since: "22"
    ]
    func toLowerCase(opt: CasingOption): Rune
    
    @!APILevel[
        since: "22"
    ]
    func toTitleCase(opt: CasingOption): Rune
}

extend Rune <: UnicodeRuneExtension {
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func isLetter(): Bool
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func isNumber(): Bool
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func isLowerCase(): Bool
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func isUpperCase(): Bool
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func isTitleCase(): Bool
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func isWhiteSpace(): Bool
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toUpperCase(): Rune
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toLowerCase(): Rune
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toTitleCase(): Rune
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toUpperCase(opt: CasingOption): Rune
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toLowerCase(opt: CasingOption): Rune
    
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toTitleCase(opt: CasingOption): Rune
}

@!APILevel[
    since: "22"
]
public interface UnicodeStringExtension {
    @!APILevel[
        since: "22"
    ]
    func isBlank(): Bool
    
    @!APILevel[
        since: "22"
    ]
    func toLower(): String
    
    @!APILevel[
        since: "22"
    ]
    func toLower(opt: CasingOption): String
    
    @!APILevel[
        since: "22"
    ]
    func toTitle(): String
    
    @!APILevel[
        since: "22"
    ]
    func toTitle(opt: CasingOption): String
    
    @!APILevel[
        since: "22"
    ]
    func toUpper(): String
    
    @!APILevel[
        since: "22"
    ]
    func toUpper(opt: CasingOption): String
    
    @!APILevel[
        since: "22"
    ]
    func trim(): String
    
    @Deprecated[message: "Use member function `func trimEnd(): String` instead."]
    @!APILevel[
        since: "22"
    ]
    func trimRight(): String
    
    @Deprecated[message: "Use member function `func trimStart(): String` instead."]
    @!APILevel[
        since: "22"
    ]
    func trimLeft(): String
    
    @!APILevel[
        since: "22"
    ]
    func trimStart(): String
    
    @!APILevel[
        since: "22"
    ]
    func trimEnd(): String
}

extend String <: UnicodeStringExtension {
    /**
    * @throws IndexOutOfBoundsException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func isBlank(): Bool
    
    /**
    * @throws NoneValueException
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toLower(): String
    
    /**
    * @throws NoneValueException
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toUpper(): String
    
    /**
    * @throws NoneValueException
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toTitle(): String
    
    /**
    * @throws NoneValueException
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toLower(opt: CasingOption): String
    
    /**
    * @throws NoneValueException
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toUpper(opt: CasingOption): String
    
    /**
    * @throws NoneValueException
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func toTitle(opt: CasingOption): String
    
    /**
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func trim(): String
    
    /**
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @Deprecated[message: "Use member function ` public func trimStart(): String` instead."]
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func trimLeft(): String
    
    /**
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @Deprecated[message: "Use member function ` public func trimEnd(): String` instead."]
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func trimRight(): String
    
    /**
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func trimStart(): String
    
    /**
    * @throws IndexOutOfBoundsException
    * @throws IllegalArgumentException
    */
    @!APILevel[
        since: "22",
        throwexception: true
    ]
    public func trimEnd(): String
}

